package com.library.service.impl;

import com.library.bean.User;
import com.library.dao.UserDao;
import com.library.dao.impl.UserDaoImpl;
import com.library.service.UserService;

/**
 * @Author:qjc
 * @Date: 2024/9/14 20:21
 * @Description:
 */
public class UserServiceImpl implements UserService {
    UserDao userDao =new UserDaoImpl();
    @Override
    public boolean userReg(User user) {
        int rowNum=userDao.userReg(user);
        if(rowNum==1){
            return true;
        }
        return false;
    }

    @Override
    public User userLoad(User user) {
        User u=userDao.userLoad(user);
        if(u!=null){
            return u;
        }
        return null;
    }
}
